home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.cs.arizona.edu
/
ftp.cs.arizona.edu.tar
/
ftp.cs.arizona.edu
/
tsql
/
doc
/
tsql.mail
/
000069_gadia@cs.iastate.edu _Mon Apr 5 16:00:01 1993.msg
< prev
next >
Wrap
Text File
|
1996-01-31
|
5KB
|
141 lines
Message-Id: <199304052100.AA20412@optima.cs.arizona.edu>
Received: from ren.cs.iastate.edu by optima.cs.arizona.edu (5.65c/15) via SMTP
id AA20412; Mon, 5 Apr 1993 14:00:07 MST
Received: by ren.cs.iastate.edu
(16.8/16.2) id AA11832; Mon, 5 Apr 93 16:00:03 -0500
From: Shashi K. Gadia <gadia@cs.iastate.edu>
Subject: Valid/Transaction times orthogonality
To: tsql@cs.arizona.edu
Date: Mon, 5 Apr 93 16:00:01 CDT
Cc: gadia@cs.iastate.edu
Mailer: Elm [revision: 70.30]
The following discussion is about
why the valid and transaction times
are orthogonal. It arose in correspondence
from Fabio Grandi. I though it may be
of general interest, so I wrote it in
a more context free style. You may read it
if you are interested.
=================================================
Pure valid time v/s pure transaction time.
------------------------------------------
The obstacle in our appreciation of the
orthogonality between the valid and transaction
times is that we typically tend to think of
valid time in isolation, but we do not think of
transaction time in isolation. So let us try
to think of the two times in isolation.
Valid time database.
--------------------
For valid time, let us suppose there is a
wizzard with E.S.P. The wizzard has the
following capabilities:
A. The wizzard knows what is changing in the
real world, as and when it changes.
B. The wizzard can remember all the past
changes.
C. The wizzard can assemble all his
knowledge in a coherent form which is
what we call a valid time database.
The problem is that a wizzard as postulated
above does is not feasible in practice. So
in valid time databases, what we do is
that we first assemble a version of histroy.
Then we allow portions of histories to be
updated through update operations. I assume
the following:
Assumption.
-----------
Updates overwrite our previous knowledge of
history and we have no way of remembering
the previous version of history.
The resulting database is still
identical to the one described above in terms
of a wizzard. Thus we have a more workable
definition of a (pure) valid time database.
Transaction time database.
--------------------------
Suppse we have a classical snapshot database.
We are updating this database to keep it
up to date (as best as we can). A transaction
time database is now obtained with the
capabilities B and C as stated above. Note that
such a database is "more than" a rollback
database.
How do the valid time database and
transaction time database compare now?
1. There is very little difference on
how users query them:
Valid-time query:
-----------------
[In reality,] When did John work in Toys?
Transaction-time query:
-----------------------
[According to our information in the
database,] when did John work in Toys?
2. Both queries are answered by the same
algebraic expression:
[[sigma (emp, Name=John, [[Dept=Toys]])]]
3. The update operations are different.
In the valid time case, we modify portions
of history. In the transaction time case
we modify the current snapshot.
Relaxing the assumptuion.
-------------------------
If we assume that not only we can modify
portions of history, but can remember previous
versions of history, we have a definition
of a bitemporal database.
Clearly, in bitemporal database there are two
time dimensions, the valid time and transaction
time. In our bitemporal model, we use finite
union of rectangles as timestamps. The above
query is now asked and formulated as follows:
Bitemporal query.
-----------------
When did John work in toys.
[[sigma (emp, Name=John, [[Dept=Toys]])]]
Again no difference!!! What does the query
retrieve? In all three cases of valid time,
transaction time and bitempopral databases,
the query is about the time stamp of the
event during which the database John is
shown to work in Toys.
"As of" queries.
----------------
"As of" are special kinds of queries which were
introduced by Ben-zwi in his bitemporal model
during 1979-81. In data processing applications
this is a very important class of queries.
Our bitemporal model.
---------------------
In our bitemporal model "as of" are very simple
queries. Our model achieves uninhibted navigation
leading to true orthogonality between valid time,
transaction time and bitemporal databases.